﻿<view:ModuleView x:Class=" UCOLOR.View.ViewBase"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"
    xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
    xmlns:dxlc="http://schemas.devexpress.com/winfx/2008/xaml/layoutcontrol"
    xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
    xmlns:dxc="http://schemas.devexpress.com/winfx/2008/xaml/charts"
    xmlns:helpers="clr-namespace:UCOLOR.Helpers"
    xmlns:view="clr-namespace:UCOLOR.View"
    mc:Ignorable="d"
    d:DesignHeight="800" d:DesignWidth="1102">

    <view:ModuleView.Resources>
        <helpers:StringFormatConverter x:Key="StringFormatConverter" />
        <helpers:ImageSourceConverter x:Key="ImageSourceConverter" />
        <Style x:Key="VerticalTile" TargetType="dxlc:Tile">
            <Setter Property="VerticalContentAlignment" Value="Center" />
            <Setter Property="HorizontalContentAlignment" Value="Center" />
            <Setter Property="Size" Value="Small" />
            <Setter Property="HeaderTemplate">
                <Setter.Value>
                    <DataTemplate />
                </Setter.Value>
            </Setter>
            <Setter Property="ContentTemplate">
                <Setter.Value>
                    <DataTemplate>
                        <StackPanel>
                            <Image Source="{Binding}" Stretch="None" />
                            <TextBlock Text="{Binding Path=Header, RelativeSource={RelativeSource AncestorType=dxlc:Tile}}" FontSize="14" Margin="0,5,0,0" HorizontalAlignment="Center" />
                        </StackPanel>
                    </DataTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="HorizontalTile" TargetType="dxlc:Tile">
            <Setter Property="VerticalContentAlignment" Value="Center" />
            <Setter Property="HorizontalContentAlignment" Value="Center" />
            <Setter Property="Size" Value="Large" />
            <Setter Property="HeaderTemplate">
                <Setter.Value>
                    <DataTemplate />
                </Setter.Value>
            </Setter>
            <Setter Property="ContentTemplate">
                <Setter.Value>
                    <DataTemplate>
                        <StackPanel Orientation="Horizontal">
                            <Image Source="{Binding}" Stretch="None" />
                            <TextBlock Text="{Binding Path=Header, RelativeSource={RelativeSource AncestorType=dxlc:Tile}}" FontSize="14" Margin="20,0,0,0" VerticalAlignment="Center" />
                        </StackPanel>
                    </DataTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="FlatTile" TargetType="dxlc:Tile">
            <Setter Property="Size" Value="Large" />
            <Setter Property="Padding" Value="0" />
            <Setter Property="VerticalHeaderAlignment" Value="Stretch" />
        </Style>
    </view:ModuleView.Resources>

    <Grid x:Name="LayoutRoot" Width="1103">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto" />
            <RowDefinition Height="*" />
        </Grid.RowDefinitions>
        <TextBlock IsHitTestVisible="False" Margin="12,12,719,23" Text="Realtor World" Foreground="#FFF78A09" FontSize="42" FontFamily="Segoe UI Light" />
        <dxlc:TileLayoutControl Grid.Row="1" Margin="10,0,0,0" Padding="20,0,20,10">
            <dxlc:Tile Style="{StaticResource HorizontalTile}" Header="站内消息" Background="#FF6652A2" Command="{Binding ShowStatisticsCommand}">
                <!--<BitmapImage UriSource="../Images/Statistics.png" />-->
            </dxlc:Tile>

            <dxlc:Tile Style="{StaticResource HorizontalTile}" Header="公告" Background="#FF6652A2" Command="{Binding ShowStatisticsCommand}" >
                <!--<BitmapImage UriSource="../Images/Statistics.png" />-->
            </dxlc:Tile>

            <dxlc:Tile Style="{StaticResource HorizontalTile}" Header="活动" Background="#FF6652A2" Command="{Binding ShowStatisticsCommand}">
                <!--<BitmapImage UriSource="../Images/Statistics.png" />-->
            </dxlc:Tile>

            <dxlc:Tile Style="{StaticResource HorizontalTile}" Header="站内消息" Background="#FF6652A2" Command="{Binding ShowStatisticsCommand}" dxlc:FlowLayoutControl.IsFlowBreak="True" Width="310" Height="150">
                <BitmapImage UriSource="../Images/Statistics.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource VerticalTile}" Header="User Management" Background="#FF00ABDC" Command="{Binding ShowUserManagementCommand}" >
                <BitmapImage UriSource="../Images/UserManagment.png" />
            </dxlc:Tile>
            <dxlc:Tile Background="#FFD4AF00" Command="{Binding ShowResearchCommand}" Header="Research" Style="{StaticResource VerticalTile}">
                <BitmapImage UriSource="../Images/Research.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource VerticalTile}" Header="System Information" Background="#FF54AF0E" Command="{Binding ShowSystemInfoCommand}">
                <BitmapImage UriSource="../Images/System.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource VerticalTile}" Header="Research" Background="#FFD4AF00" Command="{Binding ShowResearchCommand}">
                <BitmapImage UriSource="../Images/Research.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource HorizontalTile}" Header="Statistics" Background="#FF6652A2" Command="{Binding ShowStatisticsCommand}" dxlc:FlowLayoutControl.IsFlowBreak="True">
                <BitmapImage UriSource="../Images/Statistics.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource HorizontalTile}" Header="zillow.com" Background="#FFDA8515" Command="{Binding ShowZillowCommand}">
                <BitmapImage UriSource="../Images/ZillowLogo.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource VerticalTile}" Header="Mortgage Rates" Background="#FFE65E20" Command="{Binding ShowBanksCommand}">
                <BitmapImage UriSource="../Images/Rates.png" />
            </dxlc:Tile>
            <dxlc:Tile Style="{StaticResource VerticalTile}" Header="Loan Calculator" Background="#FFC3213F" Command="{Binding ShowLoanCalculatorCommand}">
                <BitmapImage UriSource="../Images/Calc.png" />
            </dxlc:Tile>
            <dxlc:Tile Background="#FF6652A2" Command="{Binding ShowStatisticsCommand}" dxlc:FlowLayoutControl.IsFlowBreak="True" Header="站内消息" Style="{StaticResource HorizontalTile}">
                <BitmapImage UriSource="../Images/Statistics.png" />
            </dxlc:Tile>
        </dxlc:TileLayoutControl>
    </Grid>
    </view:ModuleView>